<?php

namespace app\index\controller;

use think\Controller;
use think\Db;

class Orderhall extends Controller
{
    public function index(){
        $orders=Db::table('lg_order')
            ->alias('a')
            ->join('lg_user b ','b.user_id= a.order_user_id')
            ->where('a.order_status',1)
            ->where('a.order_outtime','>',time())
            ->order('a.order_ctime desc')
            ->select();
        $this->assign('orders',$orders);
        return $this->fetch();
    }
}
